import {createApp} from 'vue'
import ElementPlus from 'element-plus'
import zhCn from 'element-plus/es/locale/lang/zh-cn';
import 'element-plus/dist/index.css'
import App from './App.vue'
import router from './router/index.js'
import store from './store/index.js'
import * as ElementPlusIconsVue from '@element-plus/icons-vue'


let app = createApp(App);
//使用
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
  app.component(key, component)
}
//公共方法
import publicFn from './utils/publicFn';
// 挂载到全局
app.config.globalProperties.$Fn = publicFn

// 配置文件
import request from './request/api.js'
app.config.globalProperties.$request = request;
import config from './config/index.js'
app.config.globalProperties.$config = config;



app.use(store);
app.use(ElementPlus,{locale:zhCn});
app.use(router);
app.mount('#app')
